{% extends "base.html" %}

{% block title %}论坛-发布问答{% endblock %}

{% block head %}
    <script src="{{ url_for('static', filename='ckeditor/ckeditor.js') }}"></script>

{% endblock %}


{% block body %}
 <div class="container">
        <div class="row" style="margin-top: 20px;">
            <div class="col"></div>
            <div class="col-10">
                <h1 style="text-align: center;">发布问答</h1>
                <form action="#" method="post" enctype="multipart/form-data">
                    <div class="form-group">
                        <input type="text" name="title" class="form-control" placeholder="请输入标题">
                    </div>
                    <div class="form-group">
                        图片：<input type="file" id="uploadImage" name="uploadImage" accept="image/gif,image/png,image/jpeg,image/bmp" required/>
                    </div>

{#                    <div class="form-group">#}
{#                        <textarea name="content" class="form-control" rows="10" placeholder="请输入内容"></textarea>#}
{#                    </div>#}

                    <div class="form-group">
                         <textarea id="editor" name="content" class="form-control" rows="10" placeholder="请输入内容"></textarea>
                     </div>
                     <script>CKEDITOR.replace( 'editor' );</script>
                    <div class="form-group" style="text-align: right;">
                        <button class="btn btn-primary">发布</button>
                    </div>
                </form>
            </div>
            <div class="col"></div>
        </div>
    </div>
{% endblock %}

